<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.w3.org/1999/xhtml">
<head th:fragment="head(title)">
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title th:replace="${title}">Cenの客栈</title>
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.css">
    <link rel="stylesheet" href="../../static/lib/editormd/css/editormd.min.css"
          th:href="@{/lib/editormd/css/editormd.min.css}">
    <link rel="stylesheet" href="../static/css/me.css" th:href="@{/css/me.css}">
</head>
<body>

<!--导航-->
<nav th:fragment="menu(n)" class="ui inverted attached segment m-padded-tb-mini m-shadow-small">
    <div class="ui container">
        <div class="ui inverted secondary stackable menu">
            <h2 class="ui teal header item">Cenの客栈</h2>
            <a href="#" th:href="@{/admin/blogs}" class=" m-item item m-mobile-hide"
               th:classappend="${n==1} ? 'active'"><i class=" home icon"></i>文章管理</a>
            <a href="#" th:href="@{/admin/types}" class=" m-item item m-mobile-hide"
               th:classappend="${n==2} ? 'active'"><i class=" list icon"></i>分类管理</a>
            <a href="#" th:href="@{/admin/tags}" class="m-item item m-mobile-hide"
               th:classappend="${n==3} ? 'active'"><i class=" tags icon"></i>标签管理</a>
            <a href="#" th:href="@{/admin/pictures}" class="m-item item m-mobile-hide"
               th:classappend="${n==4} ? 'active'"><i class=" heart icon"></i>相册管理</a>
            <a href="#" th:href="@{/admin/websiteInfo}" class="m-item item m-mobile-hide"
               th:classappend="${n==5} ? 'active'"><i class=" setting icon"></i>网站设置</a>
            <div class="right m-item m-mobile-hide menu">
                <div class="ui dropdown  item">
                    <div class="text">
                        <img class="ui avatar image" src="https://unsplash.it/100/100?image=1005"
                             th:src="@{${session.user.avatar}}">
                        <span th:text="${session.user.nickname}">Cen部长</span>
                    </div>
                    <i class="dropdown icon"></i>
                    <div class="menu">
                        <a href="#" th:href="@{/admin/logout}" class="item">注销</a>
                    </div>
                </div>
            </div>
        </div>
    </div>
    <a href="#" class="ui menu toggle black icon button m-right-top m-mobile-show">
        <i class="sidebar icon"></i>
    </a>
</nav>

<!--底部footer-->
<footer th:fragment="footer" class="ui inverted vertical segment m-padded-tb-massive">
    <div class="ui center aligned container">
        <h3 class="item">小栈浏览量 : <span th:text="${session.views}" class="item m-text-thin"></span></h3>
        <h3 class="item">&nbsp;&nbsp;&nbsp;小栈已持续运行时间:<span id="htmer_time" class="item m-text-thin"></span> &nbsp;&nbsp;&nbsp;
        </h3>
        <br><br>
        <div class="ui inverted divided stackable grid">
            <!--微信二维码
            <div class="four wide column">
                <div class="ui inverted link list">
                    <a class="item" href="#"><img th:src="@{/images/wechat.png}" title="可以加我交流~"  class="ui rounded image" alt="哎呀 微信二维码摸鱼去啦" style="width: 110px"></a>
                </div>
            </div>
            -->
            <!--推荐博客-->
            <div class="five wide column">
                <h4 class="ui inverted header me-opacity-mini">小栈文章</h4>
                <div id="newblog-container">
                    <div class="ui inverted link list" th:fragment="newblogList">
                        <a href="#" th:href="@{/blog/{id}(id=${blog.id})}" target="_blank" class="item m-text-thin"
                           th:each="blog : ${newblogs}" th:text="${blog.title}"></a>
                    </div>
                </div>
            </div>
            <!--联系作者-->
            <div class="five wide column">
                <h4 class="ui inverted header me-opacity-mini">如何call我？</h4>
                <div class="ui inverted list link">
                    <p class="item">邮箱: 1249280779@qq.com</p>
                    <p class="item">QQ: 1249280779</p>
                    <p class="item">wechat: Ashely_cenxifan</p>
                    <a target="_blank" href="https://blog.csdn.net/cCENDD?spm=1000.2115.3001.5343" class="item">CSDN</a>
                </div>
            </div>
            <!--个人说明-->
            <div class="five wide column">
                <h4 class="ui inverted header me-opacity-mini">碎碎念~</h4>
                <div class="ui inverted list link">
                    <p class="item">世事繁杂</p>
                    <p class="item">我想和你</p>
                    <p class="item">过安稳的生活</p>
                </div>
            </div>
        </div>
        <div class="ui inverted section divider"></div>
        <div class="ui inverted list link">
            <p class="item">Copyright© 2022 Cen Designed by Cen_L_H</p>
            <p class="item"></p>
            <a class="item" target="_blank" href='https://beian.miit.gov.cn' style="color: #FF0066">粤ICP备2022008904号</a>
            <a class="item" target="_blank" href='' style="color: #FF0066">公安网备号（待填写）</a>
        </div>
    </div>
</footer>

<th:block th:fragment="script">
    <script src="https://cdn.jsdelivr.net/npm/jquery@3.2/dist/jquery.min.js"></script>
    <script src="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.js"></script>
    <script src="../../static/lib/editormd/editormd.min.js" th:src="@{/lib/editormd/editormd.min.js}"></script>

</th:block>

<!--鼠标点击效果-->
<script type="text/javascript">
    var a_idx = 0;
    jQuery(document).ready(function ($) {
        $("body").click(function (e) {
            var a = new Array("富强", "民主", "文明", "和谐", "自由", "平等", "公正", "法治", "爱国", "敬业", "诚信", "友善", "社会主义好", "永远跟党走", "First Blood", "Double Kill", "Triple Kill", "Quadra Kill"
                , "Penta Kill");
            var $i = $("<span/>").text(a[a_idx]);
            a_idx = (a_idx + 1) % a.length;
            var x = e.pageX, y = e.pageY;
            $i.css({
                "z-index": 100000000,
                "top": y - 20,
                "left": x,
                "position": "absolute",
                "font-weight": "bold",
                "color": "#ef5b40"
            });
            $("body").append($i);
            $i.animate({"top": y - 180, "opacity": 0}, 1500, function () {
                $i.remove();
            });
        });
    });
</script>

</body>
</html>